package utils;

import java.util.ArrayList;


import java.util.Date;
import java.util.List;

import com.jfinal.plugin.activerecord.Db;
//import com.jfinal.plugin.activerecord.Model; // 新增

import db.sysuser;



public class loginuser{  // 新增extends Model<loginuser>
	private String name;
	private String account;
//	private String password; // 新增 用于log用户修改密码
	private int id;
	
	private int userrole = 0;
	
	
	private boolean oauser = false;
	

	
	public boolean isRoleValid(int iRol) {
		if((this.userrole & iRol) == iRol) {
			return true;
		}
		return false;
	}
	
	public String getName() {
		return name;
	}
	public void setName(String name) {
		this.name = name;
	}
	public String getAccount() {
		return account;
	}
	public void setAccount(String account) {
		this.account = account;
	}
	public int getId() {
		return id;
	}
	public void setId(int id) {
		this.id = id;
	}

	public int getUserrole() {
		return userrole;
	}

	public void setUserrole(int userrole) {
		this.userrole = userrole;
	}

	public boolean isOauser() {
		return oauser;
	}

	public void setOauser(boolean oauser) {
		this.oauser = oauser;
	}

//	public void setPassword(String newPassword) { // 新增 用于log用户修改密码
//        this.password = newPassword;
//    }
//
//	public boolean update() { // 新增 用于log用户修改密码
//		return super.update();
//	}

}
